﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using FoneBuddy.LinqModel.Data;

namespace FoneBuddy.LinqModel
{
  public partial  class Subscription
    {
       #region Variable Declaration
        private IDataRepository _dataObject;
        #endregion

        public Subscription(IDataRepository dataObject): this()
        {
            _dataObject = dataObject;
        }
        public List<Subscription> GetAllSubscription()
        {
            return _dataObject.GetAllSubscription();
        }
        public void Create()
        {
            _dataObject.CreateSubscription(this);
        }
        public void Delete()
        {
            _dataObject.DeleteSubscription(this);
        }
        public void GetSubscriptionById()
        {
            _dataObject.GetSubscriptionById(this);
        }
        public void Update()
        {
            _dataObject.UpdateSubscription(this);
        }
        public void GetSubscriptionByName()
        {
             _dataObject.GetSubscriptionByName(this);
        }
    }
}
